package org.linlinjava.litemall.admin.vo.service_order;

import org.hibernate.validator.constraints.Length;
import org.linlinjava.litemall.admin.vo.locks.Address;

import javax.validation.constraints.DecimalMin;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;

/**
 * @author wj
 * @date 2021/8/13 10:25
 */
public class OnlineOrderListVo {

    @NotNull(message = "页码不能为空")
    @DecimalMin(value = "1",message = "页码不能小于1")
    private Integer page;

    @NotNull(message = "每页条数不能为空")
    @DecimalMin(value = "0",message = "每页条数不能小于0")
    private Integer limit;

    @Length(min = 11,max = 11,message = "手机号码长度不正确")
    @Pattern(regexp = "^(((13[0-9])|(14[579])|(15([0-3]|[5-9]))|(16[6])|(17[0135678])|(18[0-9])|(19[89]))\\d{8})$", message = "手机号格式错误")
    private String phone;

    private String state;

    private Address address;

    private TimeSlot time;

    public Integer getPage() {
        return page;
    }

    public void setPage(Integer page) {
        this.page = page;
    }

    public Integer getLimit() {
        return limit;
    }

    public void setLimit(Integer limit) {
        this.limit = limit;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public String getState() {
        return state;
    }

    public void setState(String state) {
        this.state = state;
    }

    public Address getAddress() {
        return address;
    }

    public void setAddress(Address address) {
        this.address = address;
    }

    public TimeSlot getTime() {
        return time;
    }

    public void setTime(TimeSlot time) {
        this.time = time;
    }
}
